#define _CRT_SECURE_NO_WARNINGS 1
#include<stdio.h>
void cfb(int a)
{
	for (int i = 1; i <= a; i++)
	{
		for (int j = 1; j <= i; j++)
		{
			printf("%d*%d=%d", j,i , i * j);
			if (i * j >= 10)
				printf("  ");
			else
				printf("    ");
		}printf("\n");
	}
}
int main()
{
	int a;
	while (scanf("%d",&a)!=EOF)
	{
		cfb(a);
	}
	return 0;
}